<div class="grid_7">
    <div class="box">
        <h2>
            <a href="#" id="toggle-tables">SPECIFICATION GROUP MANAGEMENT</a>
        </h2>
        <div class="block" >
            <form name="admin-form" action="<?= base_url(); ?>admin/specification/specification_group_insert" method="post">
                <fieldset>
                    <legend>SPECIFICATION GROUP : NEW </legend>
                    <?php
                    if ($this->session->flashdata('message')) {
                        $msg = $this->session->flashdata('message');
                        echo '<font color="red">' . $msg . '</font>';
                    }
                    ?> 
                    <div class="field">
                        <label> Specification Group Name</label>
                        <input type="text" size="50" name="specification" onfocus="if(this.value=='Enter Specification Group')this.value='';" 
                               onblur="if(this.value=='')this.value='Enter Specification Group';" value="Enter Specification Group" />
                        <input type="hidden" name="code" value="<?= $this->specification_model->get_max_code(); ?>"/>
                        <input type="submit" value="Add Specification Group" name="insert" />
                    </div>

                </fieldset>
            </form>
        </div>
    </div> <!-- END OF BOX -->
    <div class="box">
        <h2>
            <a href="#" id="toggle-tables">SPECIFICATION GROUP LIST</a>
        </h2>
        <div class="block" >
            <fieldset>
                <legend id="red">List :</legend>

                <?php foreach ($specification_group as $specification_group): ?>
                    <form name="update_make" action="<?= base_url(); ?>admin/specification/specification_group_update" method="post">
                        <div class="field">
                            <input type="hidden" size="10" name="code" value="<?= $specification_group->code; ?>" />
                            <input type="text" size="50" name="specification" value="<?= $specification_group->specification; ?>" />
                            <input type="submit" value="Update" name="update_specification_group" />
                            <div id="link-button" style="float: right">
                                <a href="<?= base_url(); ?>admin/specification/specification_group_delete/<?= $specification_group->code; ?>" class="link-button"> Delete </a>
                                <a href="<?= base_url(); ?>admin/specification/get_specification/<?= $specification_group->code; ?>" class="link-button"> View Specification </a>
                            </div>
                        </div>
                    </form>
                <?php endforeach; ?>

            </fieldset>
        </div>
        <div class="pagination" align="left"> <?php echo $this->pagination->create_links(); ?>  </div>
    </div> <!-- END OF BOX -->
</div>